<template>
  <div class="app-container">
    <el-form ref="form" :model="form" :rules="rules" label-width="180px">
      <el-form-item label="企业" prop="enterprise">
        <el-input v-model="form.enterprise" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="法总" prop="gather">
        <el-input v-model="form.gather" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="500强企业" prop="top">
        <el-input v-model="form.top" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="央企国企外企各占" prop="ratio">
        <el-input v-model="form.ratio" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="城市" prop="city">
        <el-select v-model="form.city" placeholder="请选择">
          <el-option v-for="item in dict.type.business_citys" :key="item.value" :label="item.label" :value="item.value"></el-option>
        </el-select>
      </el-form-item>
      <el-form-item label="律师" prop="lawyer">
        <el-input v-model="form.lawyer" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="律所" prop="lawfirm">
        <el-input v-model="form.lawfirm" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="专业领域" prop="major">
        <el-input v-model="form.major" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="500强法总客户推荐" prop="topReferrer">
        <el-input v-model="form.topReferrer" placeholder="请输入" />
      </el-form-item>
      <el-form-item label="有效推荐" prop="validReferrer">
        <el-input v-model="form.validReferrer" placeholder="请输入" />
      </el-form-item>
      <el-form-item>
        <el-button type="primary" @click="saveQuota">确定</el-button>
      </el-form-item>
    </el-form>
  </div>
</template>

<script>
import { getQuota, saveQuota } from "@/api/official/referrer2024/index"
export default {
  name: "User",
  dicts: ['business_citys'],
  data() {
    return {
      form: {},
      rules: {},
    }
  },
  created() {
    this.getQuota()
  },
  methods: {
    getQuota() {
      getQuota().then(response => {
        this.form = response.data
      })
    },
    saveQuota() {
      saveQuota(this.form).then(response => {
        this.$modal.msgSuccess("修改成功")
      })
    }
  }
}
</script>

<style scoped>
</style>

